﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using VideoNetApplication.Common.Helper;
using VideoNetApplication.Common.Service;
using System.Configuration;
using VideoNetApplication.Common;

namespace VideoNetApplication.Control
{
    public partial class UserLogin : BaseControl
    {
        
        public string ReturnUrl = string.Empty;
        protected void Page_Load(object sender, EventArgs e)
        {
            if (MembershipService.GetUser()!=null)
            {
                divUser.Visible = true;
                divLogin.Visible = false;
                ltrUser.Text = MembershipService.GetUser().VU_realname;
            }
            else
            {
                divUser.Visible = false;
                divLogin.Visible = true;
            }

          
            if (Request["ReturnUrl"] != null)
            {
                ReturnUrl = Request["ReturnUrl"];

            }
            else
            {
                ReturnUrl = Request.RawUrl;
            }
        }
    }
}